package com.yaoxun.bored.controller.main;

import java.util.Map;

import javax.inject.Inject;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.yaoxun.bored.service.sys.dict.DictService;

@RequestMapping("/static")
@Controller
public class StaticController {

	@Inject
	private DictService dictService;
	
	@RequestMapping(value="/dicts.json", method=RequestMethod.GET)
	@ResponseBody
	public Map<String, Object> dicts() {
		//TODO 需要优化dict查询
		return dictService.selectAllUseJs();
	}
	
}
